<template>
  <div class="addHeader">
    <span class="title">{{title}}</span>
    <span class="name" v-if="hasBtn" @click="$emit('click')">+{{btnName}}</span>
  </div>
</template>

<script>
export default {
  name: "addHeader",
  props:{
    title:{
      default:'数据字典'
    },
    btnName:{
      default: '新增字典项'
    },
    hasBtn:{
      default:true
    }
  },
}
</script>

<style scoped lang="less">
.addHeader{
  width: 159px;
  height: 48px;
  padding: 0 20px;
  background: #FFFFFF;
  border-right: 1px solid #EEEEEE;
  border-bottom: 1px solid #EEEEEE;
  display: flex;
  justify-content: space-between;
  align-items: center;
  .title{
    font-size: 14px;
    font-weight: 500;
    color: #333333;
  }
  .name{
    font-size: 12px;
    color: #1891FF;
    cursor: pointer;
    user-select: none;
  }
}
</style>
